/*
 * @Author: lp
 * @Date: 2022-01-20 11:02:06
 * @LastEditTime: 2022-04-08 17:43:41
 * @LastEditors: Please set LastEditors
 * @Description: 监控文件自动重启vite
 * @FilePath: \nien-vue3-admin\vite\plugins\restartVite.ts
 */
import ViteRestart from 'vite-plugin-restart'

export default function createRestart() {
  return ViteRestart({
    restart: [
      '.env.development',
      'vite/plugins/index.ts',
      'vite/plugins/autoImport.ts',
      'vite/plugins/components.ts',
      'src/main.ts',
      // 'vite/plugins/compression.js',
      // 'vite/plugins/html.js',
      // 'vite/plugins/mock.js',
      'vite/plugins/restartVite.ts',
      // 'vite/plugins/setup-extend.js',
      // 'vite/plugins/spritesmith.js',
      'vite/plugins/svgIcon.ts',
    ],
  })
}
